<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="chrome=1,IE=edge" />
    <title>西京文交所管理端</title>
    <link rel="stylesheet" href="../../static/iconfont/iconfont.css" >
    <link rel="stylesheet" href="../../static/frameset.css" >
</head>
<body>

    <div id="J_wrap" class="m_wrap m_box_v p_index none">
        <div class="m_top">
            <headers v-on:callback="headerHandle" :userobj.sync="userobj"></headers>
        </div>
        <div class="m_content m_flex1 m_box">
            <menunav index="collection" sub="notissued" :navobj.sync="userobj.group_acl"></menunav>
            <div class="container m_flex1">
                <ul class="breadcrumbs">
                    <li><span>藏品管理</span>&gt;</li>
                    <li class="on">未发行</li>
                </ul>
                <div class="m_toolbar" v-if="userobj.group_acl.collection.child.notissued.child.create.isOwn">
                    <a class="m_btn" href="add.html">+ 添加藏品</a>
                </div>
                <div class="m_search">
                    <input type="text" class="m_input" placeholder="藏品名称" v-model="name">
                    <adminselect :admin_id.sync="user_id" name="添加人" all="全部"></adminselect>
                    <select class="m_select" v-model="status">
                        <option value="" hidden>藏品状态</option>
                        <option value="">全部</option>
                        <option value="1">待审核</option>
                        <option value="8">审核通过</option>
                        <option value="9">审核失败</option>
                        <option value="10">待申购</option>
                    </select>
                    <button class="m_btn line" v-on:click="reSearch">查询</button>
                    <button class="m_btn line" v-on:click="reset">重置</button>
                </div>
                <table class="m_table">
                    <thead>
                        <tr>
                            <th>藏品ID</th>
                            <th>藏品名称</th>
                            <th>藏品大类</th>
                            <th>藏品类型</th>
                            <th>藏品状态</th>
                            <th>添加人</th>
                            <th>添加时间</th>
                            <th>审核人</th>
                            <th>操作</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr v-if="list.length < 1">
                            <td colspan="8">
                                <div class="tc">
                                    <template v-if="schFlag">没有符合条件的内容</template>
                                    <template v-else>暂无数据</template>
                                </div>
                            </td>
                        </tr>
                        <tr v-for="item in list" v-if="list.length > 0">
                            <td><a href="detail.html?type=1&id={{item.col_id}}" class="hightlight">{{ item.code }}</a></td>
                            <td><div class="m_textOver">{{ item.name }}</div></td>
                            <td>{{ item.type_name }}</td>
                            <td>{{ item.sub_type_name }}</td>
                            <td>{{ item.status | collectStatus }}</td>
                            <td>{{ item.user_name }}</td>
                            <td>{{ item.created_at }}</td>
                            <td>{{ item.auditor }}</td>
                            <td>
                                <template v-if="item.status == 1">
                                    <a href="javascript:void(0);" v-on:click="operate(item.col_id,8)" v-if="userobj.group_acl.collection.child.notissued.child['operate/pass'].isOwn">通过</a>
                                    <a href="javascript:void(0);" v-on:click="operate(item.col_id,9)" v-if="userobj.group_acl.collection.child.notissued.child['operate/refuse'].isOwn">拒绝</a>
                                </template>
                                <template v-if="item.status == 8">
                                    <a href="setting.html?id={{ item.col_id }}&count={{ item.count }}" v-if="userobj.group_acl.collection.child.notissued.child.set_params.isOwn">设置参数</a>
                                    <a href="add.html?id={{item.col_id}}" v-if="userobj.group_acl.collection.child.notissued.child.update.isOwn">编辑</a>
                                </template>
                                <template v-if="item.status == 9">
                                    <a href="javascript:void(0);" v-on:click="operate(item.col_id,0)" v-if="userobj.group_acl.collection.child.notissued.child.delete.isOwn">删除</a>
                                    <a href="add.html?id={{item.col_id}}" v-if="userobj.group_acl.collection.child.notissued.child.update.isOwn">编辑</a>
                                </template>
                                <template v-if="item.status == 10 && userobj.group_acl.collection.child.notissued.child.['operate/stop/buy'].isOwn">
                                    <a href="javascript:void(0);" v-on:click="operate(item.col_id,10)">停止申购</a>
                                </template>
                                <span v-else>- -</span>
                            </td>
                        </tr>
                    </tbody>
                </table>
                <pages :cur.sync="cur" :all.sync="all" v-on:btn-click="getData"></pages>
            </div>
        </div>
    </div>


    <script src="../../js/plugins/zepto/zepto.min.js"></script>
    <script src="../../js/plugins/vue/vue.min.js"></script>
    <script src="../../js/plugins/seajs/sea.js"></script>
    <script src="../../js/plugins/seajs/seajs-text.js"></script>

    <script>
        seajs.use( "../../js/page/collection/notissued" );
    </script>

</body>
</html>
